<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        *{
            margin: 0;
            padding: 0;

        }
        .box{
            position: relative;
            width: 200px;
            height: 200px;
            z-index: 1;
        }
        .box1,.box2{
            position: absolute;
            width: 100px;
            height: 100px;

        }
        .box1{
            background-color: pink;
            top: 10px;
            left: 10px;
            z-index: 9999;
        }
        .box2{
            background-color: blue;
            top: 20px;
            left: 20px;
        }
        .box3{
            position: absolute;
            top: 30px;
            left: 30px;background-color: green;
            width: 120px;
            height: 120px;
            z-index: 2;
        }
    </style>
</head>
<body>
    <div class="box">
        <div class="box1">

        </div>
        <div class="box2">

        </div>
    </div>
    <div class="box3">

    </div>
</body>
</html>